<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>后台管理系统</title>
    <link rel="stylesheet" type="text/css" href="css/bootstrap.min.css"/>
    <link rel="stylesheet" type="text/css" href="css/manager.css"/>
    <script src="js/bootstrap.min.js"></script>
    <script src="js/jquery-3.3.1.min.js"></script>
</head>
<body>
    <div class="container" id="manager_body">
        <div class="row" id="manager_body_row">
            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2" id="manager_body_left">
                <div id="left_title">乐享生活后台管理</div>
                <div class="space" id="shop_father"><img src="images/managershop.png" /><span>系统店铺管理</span></div>
                <div class="shop_child space hover" id="shop1"><span>店铺信息管理</span></div>
                <div class="shop_child space hover" id="shop2"><span>店铺信息审核</span></div>
                <div class="space goods_father"><img src="images/managergoods.png" /><span>系统商品管理</span></div>
                <div class="shop_child space hover" id="goods1"><span>商品信息管理</span></div>
                <div class="shop_child space hover" id="goods2"><span>商品信息审核</span></div>
                <div class="space goods_father"><img src="images/managerorder.png" /><span>系统订单管理</span></div>
                <div class="shop_child space hover" id="order"><span>订单信息管理</span></div>
                <div class="space goods_father"><img src="images/managerpinglun.png" /><span>系统评论管理</span></div>
                <div class="shop_child space hover" id="evaluate"><span>评论信息管理</span></div>
                <div class="space goods_father"><img src="images/manageruser.png" /><span>系统用户管理</span></div>
                <div class="shop_child space hover" id="user"><span>用户信息管理</span></div>
            </div>
            <div class="col-xs-10 col-sm-10 col-md-10 col-lg-10" id="manager_body_right">
                <div class="row" id="right_top"></div>
                <div class="row" id="right_bottom">
                    <img src="images/login/login_left_logo.png" id="bg_size">
                </div>
            </div>
        </div>
    </div>

    <script type="text/javascript">

        $("#shop1").click(function () {
            $("#right_top").html("<div id='right_title'><span>店铺信息列表</span></div>");
            loadShop1(1);
        });

        function loadShop1(page) {
            $.post("shop/getShopList",{what:"",page:page,pageSize:17},function (data) {
                data = JSON.parse(data);
                var ht = '<div class="row shoprowtitle">\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">名称</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">店主</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">商品数量</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">累计销量</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">店铺状态</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">操作</div>\n' +
                    '        </div>';

                for (var i = 0; i < data.shops.length; i++) {
                    ht += '<div class="row shoprow">\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">'+ data.shops[i].shopname +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">'+ data.shops[i].user.name +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">'+ data.shops[i].goodsnum +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">'+ data.shops[i].sellnum +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">营业中</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop"><a class="del" data-id="'+ data.shops[i].id +'">封禁</a></div>\n' +
                        '  </div>';
                }

                ht += '<div id="pageinfo">共'+ Math.ceil(data.total/17) +'页，当前为第'+ page +'页<button id="prev">上一页</button><button id="next">下一页</button></div>'

                $("#right_bottom").html(ht);

                $("#prev").click(function () {
                    if (page > 1){
                        loadShop1(parseInt(page)-1);
                    }
                });

                $("#next").click(function () {
                    if (page < Math.ceil(data.total/17)){
                        loadShop1(parseInt(page)+1);
                    }
                });

                var pagesum = Math.ceil(data.total/17);

                $(".del").click(function () {
                    var id = $(this).attr("data-id");
                    $.post("shop/delShop",{id:id},function (data) {
                        data = JSON.parse(data);
                        if (data.code.toLowerCase() == "success"){
                            alert("店铺封禁成功!");
                            if (page == pagesum) {
                                if ($(".del").length == 1){
                                    loadShop1(parseInt(page)-1);
                                }else {
                                    loadShop1(page);
                                }
                            }else {
                                loadShop1(page);
                            }
                        }else {
                            alert("店铺封禁失败!");
                        }
                    });
                });
                
            });
        }

        $("#shop2").click(function () {
            $("#right_top").html("<div id='right_title'><span>店铺审批列表</span></div>");
            loadShop2(1);
        });

        function loadShop2(page) {
            $.post("shop/getShopList2",{page:page,pageSize:13},function (data) {
                data = JSON.parse(data);

                var ht = '<div class="row yunshoptitle">\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">店铺名称</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">店铺头像</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">申请用户</div>\n' +
                    '            <div class="col-xs-4 col-sm-4 col-md-4 col-lg-4">申请理由</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">操作</div>\n' +
                    '      </div>';
                for (var i = 0; i < data.shops.length; i++) {
                    ht+= '<div class="row yunshop">\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 yunshopa">'+ data.shops[i].shopname +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 yunshopa"><img src="/FVOnline/shop/getHS?userId='+ data.shops[i].user.id +'" class="imgsize"></div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 yunshopa">'+ data.shops[i].user.name +'</div>\n' +
                        '            <div class="col-xs-4 col-sm-4 col-md-4 col-lg-4 yunshopa">'+ data.shops[i].reason +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 yunshopa"><a class="add" data-id="'+ data.shops[i].id +'">审核通过</a></div>\n' +
                        '  </div>';
                }

                ht += '<div id="pageinfo">共'+ Math.ceil(data.total/13) +'页，当前为第'+ page +'页<button id="prev">上一页</button><button id="next">下一页</button></div>'

                $("#right_bottom").html(ht);

                $("#prev").click(function () {
                    if (page > 1){
                        loadShop2(parseInt(page)-1);
                    }
                });

                $("#next").click(function () {
                    if (page < Math.ceil(data.total/13)){
                        loadShop2(parseInt(page)+1);
                    }
                });

                var pagesum = Math.ceil(data.total/13);

                $(".add").click(function () {
                    var id = $(this).attr("data-id");
                    $.post("shop/addShop",{id:id},function (data) {
                        data = JSON.parse(data);
                        if (data.code.toLowerCase() == "success"){
                            alert("店铺审核成功!");
                            if (page == pagesum) {
                                if ($(".add").length == 1){
                                    loadShop2(parseInt(page)-1);
                                }else {
                                    loadShop2(page);
                                }
                            }else {
                                loadShop2(page);
                            }
                        }else {
                            alert("店铺封禁失败!");
                        }
                    });
                });


            });
        }

        $("#goods1").click(function () {
            $("#right_top").html("<div id='right_title'><span>商品信息列表</span></div>");
            loadGoods1(1);
        });

        function loadGoods1(page) {
            $.post("goods/getGoodsList",{what:"",page:page,pageSize:17},function (data) {
                data = JSON.parse(data);
                
                var ht = ' <div class="row goodsrowtitle">\n' +
                    '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">商品名称</div>\n' +
                    '                        <div class="col-xs-4 col-sm-4 col-md-4 col-lg-4">商品描述</div>\n' +
                    '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">商品价格</div>\n' +
                    '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">商品状态</div>\n' +
                    '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">操作</div>\n' +
                    '                    </div>';

                for (var i = 0; i < data.goods.length; i++) {
                    ht += '<div class="row goodsrow">\n' +
                        '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 goods">'+ data.goods[i].goodsname +'</div>\n' +
                        '                        <div class="col-xs-4 col-sm-4 col-md-4 col-lg-4 goods">'+ data.goods[i].details +'</div>\n' +
                        '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 goods">'+ data.goods[i].price +'</div>\n' +
                        '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 goods">正在销售</div>\n' +
                        '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 goods"><a class="del" data-id="'+ data.goods[i].id +'">商品封禁</a></div>\n' +
                        '                    </div>';
                }

                ht += '<div id="pageinfo">共'+ Math.ceil(data.total/17) +'页，当前为第'+ page +'页<button id="prev">上一页</button><button id="next">下一页</button></div>'

                $("#right_bottom").html(ht);


                $("#prev").click(function () {
                    if (page > 1){
                        loadGoods1(parseInt(page)-1);
                    }
                });

                $("#next").click(function () {
                    if (page < Math.ceil(data.total/17)){
                        loadGoods1(parseInt(page)+1);
                    }
                });

                var pagesum = Math.ceil(data.total/17);

                $(".del").click(function () {
                    var id = $(this).attr("data-id");
                    $.post("goods/delGoods",{id:id},function (data) {
                        data = JSON.parse(data);
                        if (data.code.toLowerCase() == "success"){
                            alert("商品封禁成功!");
                            if (page == pagesum) {
                                if ($(".del").length == 1){
                                    loadGoods1(parseInt(page)-1);
                                }else {
                                    loadGoods1(page);
                                }
                            }else {
                                loadGoods1(page);
                            }
                        }else {
                            alert("商品封禁失败!");
                        }
                    });
                });

            });
        }

        $("#goods2").click(function () {
            $("#right_top").html("<div id='right_title'><span>商品审批列表</span></div>");
            loadGoods2(1);
        });

        function loadGoods2(page) {
            $.post("goods/getGoodsList2",{what:"",page:page,pageSize:13},function (data) {
                data = JSON.parse(data)
                var ht = '<div class="row goodsrowtitle">\n' +
                    '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">商品名称</div>\n' +
                    '                        <div class="col-xs-4 col-sm-4 col-md-4 col-lg-4">商品描述</div>\n' +
                    '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">商品图片</div>\n' +
                    '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">商品价格</div>\n' +
                    '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">操作</div>\n' +
                    '    </div>';

                for (var i = 0; i < data.goods.length; i++) {
                    ht += '<div class="row goodsrow">\n' +
                        '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 goods">'+ data.goods[i].goodsname +'</div>\n' +
                        '                        <div class="col-xs-4 col-sm-4 col-md-4 col-lg-4 goods">'+ data.goods[i].details +'</div>\n' +
                        '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 goods"><img src="/FVOnline/goods/getImg?goodsId='+ data.goods[i].id +'"></div>\n' +
                        '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 goods">'+ data.goods[i].price +'</div>\n' +
                        '                        <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 goods"><a class="add" data-id="'+ data.goods[i].id +'">审核通过</a></div>\n' +
                        '</div>';
                }

                ht += '<div id="pageinfo">共'+ Math.ceil(data.total/13) +'页，当前为第'+ page +'页<button id="prev">上一页</button><button id="next">下一页</button></div>'

                $("#right_bottom").html(ht);

                $("#prev").click(function () {
                    if (page > 1){
                        loadGoods2(parseInt(page)-1);
                    }
                });

                $("#next").click(function () {
                    if (page < Math.ceil(data.total/13)){
                        loadGoods2(parseInt(page)+1);
                    }
                });

                var pagesum = Math.ceil(data.total/13);

                $(".add").click(function () {
                    var id = $(this).attr("data-id");
                    $.post("goods/addGoods",{id:id},function (data) {
                        data = JSON.parse(data);
                        if (data.code.toLowerCase() == "success"){
                            alert("商品审核成功!");
                            if (page == pagesum) {
                                if ($(".add").length == 1){
                                    loadGoods2(parseInt(page)-1);
                                }else {
                                    loadGoods2(page);
                                }
                            }else {
                                loadGoods2(page);
                            }
                        }else {
                            alert("商品审核失败!");
                        }
                    });

                });

            })
        }

        $("#order").click(function () {
            $("#right_top").html("<div id='right_title'><span>店铺信息列表</span></div>");
            loadOrder("",1);
        });

        function loadOrder(what,page) {

            $.post("order/getOrders",{what:what,page:page,pageSize:16},function (data) {
                data = JSON.parse(data);

                var ht = '<div id="orderfind">订单编号：<input type="text" autocomplete="off" id="sea"><button id="sub">搜索</button></div>' +
                    ' <div class="row orderrowtitle">\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">订单编号</div>\n' +
                    '            <div class="col-xs-1 col-sm-1 col-md-1 col-lg-1">快递名称</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">快递单号</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">创建时间</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">支付时间</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">发货时间</div>\n' +
                    '            <div class="col-xs-1 col-sm-1 col-md-1 col-lg-1">订单状态</div>\n' +
                    '        </div>';

                for (var i = 0; i < data.orders.length; i++) {

                    var expressnumber,expressname,sendtime,state;
                    if (data.orders[i].state < 2){
                        expressnumber = '';
                        expressname = '';
                        sendtime = '';
                    }else {
                        expressnumber = data.orders[i].expressNumber;
                        expressname = data.orders[i].expressName;
                        sendtime = data.orders[i].sendTime;
                    }

                    if (data.orders[i].state == 0){
                        state = '待付款';
                    }else if (data.orders[i].state == 1) {
                        state = '待发货';
                    }else if (data.orders[i].state == 2){
                        state = '待收货';
                    } else if (data.orders[i].state == 3){
                        state = '待评价';
                    }else if (data.orders[i].state == 4){
                        state = '已完成';
                    }


                    ht  += '<div class="row shoprow">\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">'+ data.orders[i].orderNumber +'</div>\n' +
                        '            <div class="col-xs-1 col-sm-1 col-md-1 col-lg-1 shop">'+ expressname +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">'+ expressnumber +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">'+ data.orders[i].createTime +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">'+ data.orders[i].payTime +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">'+ sendtime +'</div>\n' +
                        '            <div class="col-xs-1 col-sm-1 col-md-1 col-lg-1 shop"><span>'+ state +'</span></div>\n' +
                        '        </div>';

                }


                ht += '<div id="pageinfo">共'+ Math.ceil(data.total/16) +'页，当前为第'+ page +'页<button id="prev">上一页</button><button id="next">下一页</button></div>'

                $("#right_bottom").html(ht);

                $("#sea").val(what);

                $("#prev").click(function () {
                    if (page > 1){
                        loadOrder(what,parseInt(page)-1);
                    }
                });

                $("#next").click(function () {
                    if (page < Math.ceil(data.total/16)){
                        loadOrder(what,parseInt(page)+1);
                    }
                });

                $("#sub").click(function () {
                    var what = $("#sea").val();
                    loadOrder(what,1);
                });


            });
        }

        $("#evaluate").click(function () {
            $("#right_top").html("<div id='right_title'><span>评论信息列表</span></div>");
            loadEvaluate("",1);
        });

        function loadEvaluate(what,page) {
            $.post("evaluate/getEvaluate",{what:what,page:page,pageSize:15},function (data) {

                data = JSON.parse(data);

                var ht = '<div id="orderfind">评论内容：<input id="sea"><button id="sub">搜索</button></div>' +
                    '<div class="row prowtitle">\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">评价用户</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">评价商品</div>\n' +
                    '            <div class="col-xs-5 col-sm-5 col-md-5 col-lg-5 shop">评价内容</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 shop">评价时间</div>\n' +
                    '            <div class="col-xs-1 col-sm-1 col-md-1 col-lg-1 shop">操作</div>\n' +
                    '        </div>';

                for (var i = 0; i < data.evaluates.length; i++) {
                    ht += '<div class="row prow">\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 p">'+ data.evaluates[i].user.username +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 p">'+ data.evaluates[i].goods.goodsname +'</div>\n' +
                        '            <div class="col-xs-5 col-sm-5 col-md-5 col-lg-5 p">'+ data.evaluates[i].evaluate +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 p">'+ data.evaluates[i].time +'</div>\n' +
                        '            <div class="col-xs-1 col-sm-1 col-md-1 col-lg-1 p"><a class="del" data-id="'+ data.evaluates[i].id +'">删除</a></div>\n' +
                        '        </div>';
                }

                ht += '<div id="pageinfo">共'+ Math.ceil(data.total/15) +'页，当前为第'+ page +'页<button id="prev">上一页</button><button id="next">下一页</button></div>'

                $("#right_bottom").html(ht);

                $("#sea").val(what);

                $("#prev").click(function () {
                    if (page > 1){
                        loadEvaluate(what,parseInt(page)-1);
                    }
                });

                $("#next").click(function () {
                    if (page < Math.ceil(data.total/15)){
                        loadEvaluate(what,parseInt(page)+1);
                    }
                });

                $("#sub").click(function () {
                    var what = $("#sea").val();
                    loadEvaluate(what,1);
                });


                var pagesum = Math.ceil(data.total/15);

                $(".del").click(function () {
                    var id = $(this).attr("data-id");
                    $.post("evaluate/delEvaluate",{id:id},function (data) {
                        data = JSON.parse(data);
                        if (data.code.toLowerCase() == "success"){
                            alert("评论删除成功!");
                            if (page == pagesum) {
                                if ($(".del").length == 1){
                                    loadEvaluate(what,parseInt(page)-1);
                                }else {
                                    loadEvaluate(what,page);
                                }
                            }else {
                                loadEvaluate(what,page);
                            }
                        }else {
                            alert("评论删除失败!");
                        }
                    });
                });


            });
        }

        $("#user").click(function () {
            $("#right_top").html("<div id='right_title'><span>用户信息列表</span></div>");
            loadUser("",1);
        });

        function loadUser(what,page) {
            $.post("user/getUser",{what:what,page:page,pageSize:10},function (data) {

                data = JSON.parse(data);

                var ht = '<div id="orderfind">手机号码：<input id="sea"><button id="sub">查询</button></div>' +
                    '<div class="row urowtitle">\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">用户ID</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">头像</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">昵称</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">手机号码</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">累计消费</div>\n' +
                    '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">操作</div>\n' +
                    '      </div>';

                for (var i = 0; i < data.users.length; i++) {

                    var username = '';

                    if (data.users[i].username == null){
                        username = 'fvonline_' + data.users[i].id;
                    }else {
                        username = data.users[i].username;
                    }

                    ht += '<div class="row urow">\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 u">'+ data.users[i].id +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 u"><img src="/FVOnline/user/getHS?userId='+ data.users[i].id +'"></div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 u">'+ username +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 u">'+ data.users[i].telephone +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 u">'+ data.users[i].integral +'</div>\n' +
                        '            <div class="col-xs-2 col-sm-2 col-md-2 col-lg-2 u"><a class="del" data-id="'+ data.users[i].id +'">账号封禁</a></div>\n' +
                        '        </div>';
                }

                ht += '<div id="pageinfo">共'+ Math.ceil(data.total/10) +'页，当前为第'+ page +'页<button id="prev">上一页</button><button id="next">下一页</button></div>'

                $("#right_bottom").html(ht);

                $("#sea").val(what);

                $("#prev").click(function () {
                    if (page > 1){
                        loadUser(what,parseInt(page)-1);
                    }
                });

                $("#next").click(function () {
                    if (page < Math.ceil(data.total/10)){
                        loadUser(what,parseInt(page)+1);
                    }
                });

                $("#sub").click(function () {
                    var what = $("#sea").val();
                    loadUser(what,1);
                });


                var pagesum = Math.ceil(data.total/10);

                $(".del").click(function () {
                    var id = $(this).attr("data-id");
                    $.post("user/delUser",{id:id},function (data) {
                        data = JSON.parse(data);
                        if (data.code.toLowerCase() == "success"){
                            alert("用户封禁成功!");
                            if (page == pagesum) {
                                if ($(".del").length == 1){
                                    loadUser(what,parseInt(page)-1);
                                }else {
                                    loadUser(what,page);
                                }
                            }else {
                                loadEvaluate(what,page);
                            }
                        }else {
                            alert("用户封禁失败!");
                        }
                    });
                });

            })
        }
    </script>
</body>
</html>